package com.longqin.business.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDate;
import java.time.LocalDateTime;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;

/**
 * <p>
 * 项目管理
 * </p>
 *
 * @author longqin
 * @since 2025-01-21
 */
@Getter
@Setter
@TableName("bus_project")
@ApiModel(value = "BusProject对象", description = "项目管理")
public class BusProject implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("主键")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty("项目名称")
    @TableField("project_name")
    private String projectName;

    @ApiModelProperty("项目编号")
    @TableField("project_code")
    private String projectCode;

    @ApiModelProperty("创建人")
    @TableField("creator")
    private Integer creator;

    @ApiModelProperty("创建时间")
    @TableField("create_time")
    private LocalDateTime createTime;

    @ApiModelProperty("组织机构ID")
    @TableField("organization_id")
    private Integer organizationId;

    @ApiModelProperty("状态：1-编制，2-审核，3-进行中，4-暂停，5-终止，6-结项，0-删除")
    @TableField("status")
    private Integer status;

    @ApiModelProperty("项目经理id")
    @TableField("project_manager")
    private Integer projectManager;

    @ApiModelProperty("开发部门id")
    @TableField("department_id")
    private Integer departmentId;

    @ApiModelProperty("产品经理id")
    @TableField("product_manager")
    private Integer productManager;

    @ApiModelProperty("项目类型")
    @TableField("project_type")
    private Integer projectType;

    @ApiModelProperty("开始时间")
    @TableField("begin_date")
    private LocalDate beginDate;

    @ApiModelProperty("实际结束时间")
    @TableField("end_date")
    private LocalDate endDate;
    
    @ApiModelProperty("计划结束时间")
    @TableField("plan_end_date")
    private LocalDate planEndDate;

    @ApiModelProperty("背景")
    @TableField("project_background")
    private String projectBackground;

    @ApiModelProperty("目标")
    @TableField("project_target")
    private String projectTarget;

    @ApiModelProperty("风险")
    @TableField("project_risk")
    private String projectRisk;

    @ApiModelProperty("附件")
    @TableField("attachments")
    private String attachments;
    
    @ApiModelProperty("项目经理")
    @TableField(exist = false)
    private String projectManagerName;
    
    @ApiModelProperty("产品经理")
    @TableField(exist = false)
    private String productManagerName;

    @ApiModelProperty("发起人")
    @TableField(exist = false)
    private String userName;
    
    @ApiModelProperty("开发部门")
    @TableField(exist = false)
    private String departmentName;
    
    @ApiModelProperty("当前阶段")
    @TableField(exist = false)
    private String milestoneName;
    
    @ApiModelProperty("阶段里程碑")
    @TableField(exist = false)
    private String milestoneDate;
    
    @ApiModelProperty("里程碑列表")
    @TableField(exist = false)
    private BusProjectMilestone[] milestones;
    
    @ApiModelProperty("项目组成员")
    @TableField(exist = false)
    private BusProjectMember[] members;
    
    @ApiModelProperty("需求id列表")
    @TableField(exist = false)
    private Integer[] requirments;
    
    @ApiModelProperty("需求列表")
    @TableField(exist = false)
    private BusRequirement[] requirmentList;
    
    @ApiModelProperty("流程工作进程ID")
    @TableField(exist = false)
    private Integer processId;
    
    @ApiModelProperty("实例节点配置项")
    @TableField(exist = false)
    private String workNodes;
}
